The present invention relates to an image processing apparatus and method as well as a profile generating method, and more particularly, to an image processing apparatus and method for performing color matching according to ambient light, and a profile generating method.
FIG. 1 is a conceptual view of general color matching.
Input RGB data is converted by an input profile to XYZ data of a color space which does not depend on any devices. Since an output device cannot express colors outside the color reproduction range of the output device, gamut mapping is performed on the inputted data, which has been converted to the data in the device-independent color space, such that all colors of the inputted data fall within the color reproduction range of the output device. After the gamut mapping is performed, the inputted data is converted from the device-independent color space to CMYK data of a color space which is dependent on the output device.
In color matching, a reference white point and ambient light are fixed. For instance, according to a profile specified by the International Color Consortium (ICC), Profile Connection Space (PCS) for associating profiles uses XYZ values or Lab values based on D50 characteristic. Therefore, correct color reproduction is guaranteed when an inputted original document and a printout are viewed under an illuminant of D50 characteristic. Under an illuminant of other characteristics, correct color reproduction is not guaranteed.
When a sample (e.g., an image) is viewed under different illuminants, XYZ values of the viewed sample naturally vary. The XYZ values under various illuminants are predicted by conversion methods such as (1) scaling operation, (2) Von Kries conversion, and (3) prediction formula using a color appearance model.
In the scaling operation method, XYZ values under a reference white point W1 are converted to XYZ values under a reference white point W2 at a ratio of W2/W1. If this conversion method is applied to the Lab uniform color space, the Lab values under W1 become equal to the Lab values under W2. Assuming that XYZ values of a sample under W1(Xw1, Yw1, Zw1) are (X1, Y1, Z1) and XYZ values of the sample under W2(Xw2, Yw2, Zw2) are (X2, Y2, Z2), the following relations are obtained by the scaling operation:                                                                         X2                =                                                                            X                      ⁢                                                                                           ⁢                      w2                                                              X                      ⁢                                                                                           ⁢                      w1                                                        ⁢                  X1                                                                                                        Y2                =                                                                            Y                      ⁢                                                                                           ⁢                      w2                                                              Y                      ⁢                                                                                           ⁢                      w1                                                        ⁢                  Y1                                                                                                        Z2                =                                                                            Z                      ⁢                                                                                           ⁢                      w2                                                              Z                      ⁢                                                                                           ⁢                      w1                                                        ⁢                  Z1                                                                    }                            (        1        )            
According to the Von Kries conversion, XYZ values under the reference white point W1 are converted to XYZ values under the reference white point W2 at a ratio of W2′/W1′ in a human color perception space PQR. If this conversion method is applied to the Lab uniform color space, the Lab values under W1 do not become equal to the Lab values under W2. Assuming that XYZ values of a sample under W1(Xw1, Yw1, Zw1) are (X1, Y1, Z1) and XYZ values of the sample under W2(Xw2, Yw2, Zw2) are (X2, Y2, Z2), the following relations are obtained by Von Kries conversion:                                           [                                                                                X                    ⁢                                                                                   ⁢                    2                                                                                                                    Y                    ⁢                                                                                   ⁢                    2                                                                                                                    Z                    ⁢                                                                                   ⁢                    2                                                                        ]                    =                                                                      [                  inv_Mat                  ]                                ⁢                                                                   [                                                                                                                              P                          ⁢                                                                                                           ⁢                          w                          ⁢                                                                                                           ⁢                          2                                                                          P                          ⁢                                                                                                           ⁢                          w                          ⁢                                                                                                           ⁢                          1                                                                                                            0                                                              0                                                                                                  0                                                                                                                Q                          ⁢                                                                                                           ⁢                          w                          ⁢                                                                                                           ⁢                          2                                                                          Q                          ⁢                                                                                                           ⁢                          w                          ⁢                                                                                                           ⁢                          1                                                                                                            0                                                                                                  0                                                              0                                                                                                                R                          ⁢                                                                                                           ⁢                          w                          ⁢                                                                                                           ⁢                          2                                                                          R                          ⁢                                                                                                           ⁢                          w                          ⁢                                                                                                           ⁢                          1                                                                                                                    ]                            ⁡                              [                                                                                                                                                                                                                                                     M                        ⁢                                                                                                   ⁢                        a                        ⁢                                                                                                   ⁢                        t                                                                                                                                                                                                                                             ]                                      ⁡                          [                                                                                          X                      ⁢                                                                                           ⁢                      1                                                                                                                                  Y                      ⁢                                                                                           ⁢                      1                                                                                                                                  Z                      ⁢                                                                                           ⁢                      1                                                                                  ]                                      ⁢                                  ⁢                  w          ⁢                                           ⁢          h          ⁢                                           ⁢          e          ⁢                                           ⁢          r          ⁢                                           ⁢          e                                    (        2        )                                          [                                                                      P                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  2                                                                                                      Q                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  2                                                                                                      R                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  2                                                              ]                =                              [                                                                                                                                                                                                     M                    ⁢                                                                                   ⁢                    a                    ⁢                                                                                   ⁢                    t                                                                                                                                                                                             ]                    ⁢                                           [                                                                      X                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  2                                                                                                      Y                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  2                                                                                                      Z                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  2                                                              ]                                    (        3        )                                          [                                                                      P                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  1                                                                                                      Q                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  1                                                                                                      R                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  1                                                              ]                =                              [                                                                                                                                                                                                     M                    ⁢                                                                                   ⁢                    a                    ⁢                                                                                   ⁢                    t                                                                                                                                                                                             ]                    ⁢                                           [                                                                      X                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  1                                                                                                      Y                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  1                                                                                                      Z                  ⁢                                                                           ⁢                  w                  ⁢                                                                           ⁢                  1                                                              ]                                    (        4        )                                          [                                                                                                                                                           inv_Mat                                                                                                                                                     ]                =                  [                                                    1.85995                                                              -                  1.12939                                                            0.21990                                                                    0.36119                                            0.63881                                            0                                                                    0                                            0                                            1.08906                                              ]                                    (        5        )                                          [                                                                                                                                                                             M                  ⁢                                                                           ⁢                  a                  ⁢                                                                           ⁢                  t                                                                                                                                                                     ]                =                  [                                                    0.44024                                            0.70760                                                              -                  0.08081                                                                                                      -                  0.22630                                                            1.16532                                            0.04570                                                                    0                                            0                                            0.91822                                              ]                                    (        6        )            
To convert XYZ values under a viewing condition VC1 (including W1) to XYZ values under a viewing condition VC2 (including W2), the prediction formula using a color appearance model, which is a conversion method such as CIE CAM 97s using the human color perception space QMH (or JCH) is employed. Herein, Q for QMH represents brightness, M represents colorfulness, and H represents hue quadrature or hue angle. J for JCH represents lightness, C represents chroma, and H represents hue quadrature or hue angle. If this conversion method is applied to the Lab uniform color space, the Lab values under W1 are not equal to the Lab values under W2, as similar to the case of the Von Kries conversion. Assuming that XYZ values of a sample under W1(Xw1, Yw1 Zw1) are (X1, Y1, Z1) and XYZ values of the sample under W2(Xw2, Yw2, Zw2) are (X2, Y2, Z2), the Von Kries conversion performs the following conversion:(X1, Y1, Z1)→[forward conversion of CIE CAM97s]→(Q, M, H) or (J, C, H)→[inverse conversion of CIE CAM97s]→(X2, Y2, Z2) 
In other words, if it is assumed that XYZ values under a reference white point which varies depending on a scaling operation can be converted, the contour lines of hue in the Lab color spaces under various reference white points are always the same. However, if human color perception is taken into consideration, such as the Von Kries conversion or prediction formula using a color appearance model, the contour lines of hue in the Lab color spaces under different reference white points vary depending on the reference white points.
Because of the above reason, if gamut mapping (hue restoration) defined under one Lab color space is applied to color matching under different reference white points, the human vision perceives the hue as inconsistent.
Moreover, in the current ICC profile, since the PCS is limited to XYZ values or Lab values based on D50 characteristic, color matching corresponding to ambient light cannot be performed.